package com.summer.framework.api.feign.fallback.stream;

import com.summer.framework.api.dto.Msg;
import com.summer.framework.api.feign.service.stream.StreamApiService;
import lombok.Setter;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

/**
 * @auther: 杨杰
 * @date: 2019/5/13 14:06
 * @description:
 */
@Slf4j
@Component
public class StreamApiServiceFallBack implements StreamApiService {
    @Setter
    private Throwable cause;

    @Override
    public boolean send(Msg msg) {
        log.info("出现错误", cause);
        return false;
    }

    @Override
    public int save() {
        return 0;
    }

    @Override
    public int get() {
        return 0;
    }
}
